function [ accuracy, sensitivity, specificity ] = calc_classification_performance( Y, Y_hat )

TP = nnz( Y==1 & Y_hat==1);
FP = nnz( Y~=1 & Y_hat==1);
TN = nnz( Y~=1 & Y_hat~=1);
FN = nnz( Y==1 & Y_hat~=1);

accuracy = (TP + TN)/(TP + FP + TN + FN);
sensitivity = TP/(TP + FN);
specificity = TN/(FP + TN);

end
